#ifndef __CORRESPONDENT_H__
#define __CORRESPONDENT_H__

#include "gmsi.h"
#include "userconfig.h"

#define CHECK_HEAD(A,B)     ((A==0x47)&&(B==0x4D)?true:false)

typedef struct{
    pfcnWrite Write;
    pfcnRead Read;
    uint32_t wFd;
}correspondent_cfg_t;

typedef struct{
    gmsi_base_t *ptBase;

    pfcnWrite Write;
    pfcnRead Read;
    uint32_t wFd;
    
    uint16_t hwPollCount;
}correspondent_t;

int correspondent_Init(uintptr_t wObjectAddr, uintptr_t wObjectCfgAddr);

#endif